using System;
using System.Collections.Generic;
using System.Text;

using DataAccess;

namespace Task.Contracts
{
    /// <summary>
    /// Forum taks interface.
    /// </summary>
    public interface IForumTask
    {
        /// <summary>
        /// Adds the forum.
        /// </summary>
        /// <param name="forumTemp">The forum temp.</param>
        void AddForum(forum forumTemp, int userId);
		List<DataAccess.forum> GetAllForums();
		List<DataAccess.comment> GetComments(int forumId, int start, int howMany);
		List<DataAccess.comment> GetComments(DataAccess.forum forum, int start, int howMany);
		List<DataAccess.forum> GetForumsByNewestComment(int start, int howMany);
		int AddComment(DataAccess.forum forum, DataAccess.user user, DataAccess.comment comment);
		int AddComment(int forum_id, int user_id, DataAccess.comment comment, params int[] parentCommentId);
		List<DataAccess.forum> GetForumsByNewestCommentForUser(int start, int howMany, int user_id);
		List<DataAccess.forum> GetOwnedForums(int start, int howMany, int user_id);
		List<DataAccess.forum> SearchForums(string searchedText);
		int GetMyOwnerForumsCount(int ownerid);
		int GetMyForumsCount(int userid);
		void DeleteOwnerForum(int user_id, int forum_id);
		int GetCommentsCount(int forum_id);
		int ForumOwnerId(int forum_id);
		bool IsSignedUser(int forum_id, int user_id);
		List<comment> TopicListByDate(int forum_id);
		comment NewestCommentInTopic(int parentComment_id);
		List<DataAccess.comment> GetCommentsForParentComment(int commentId, int forumId, int start, int howMany);
		int CountCommentsInTopic(int forum_id, int parrentComment_id);
		int CountTopicsInForum(int forum_id);
		void SignToForum(int user_id, int forum_id);
		void unSignFromForum(int user_id, int forum_id);

	}
}
